'use strict';

/**
 * @param {Egg.Application} app - egg application
 */
module.exports = app => {
  const { router, controller } = app;
  router.get('/', controller.home.index);
  //新增
  router.post('/put',controller.home.put);
  //更新
  router.post('/update',controller.home.update);
  //查询
  router.get('/bookslist',controller.home.bookslist);
  //删除
  router.get('/del',controller.home.del);
  router.post('/api/registry',controller.user.registry);
  router.post('/api/login',controller.user.login);
};
